Skip to content

Method: static {...}

1: /*
2: * Copyright © 2021 Fachhochschule für die Wirtschaft (FHDW) Hannover
3: *
4: * This file is part of ipspiel21-tictactoe-core.
5: *
6: * ipspiel21-tictactoe-core is free software: you can redistribute it and/or modify it under
7: * the terms of the GNU General Public License as published by the Free Software
8: * Foundation, either version 3 of the License, or (at your option) any later
9: * version.
10: *
11: * ipspiel21-tictactoe-core is distributed in the hope that it will be useful, but WITHOUT
12: * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
13: * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
14: * details.
15: *
16: * You should have received a copy of the GNU General Public License along with
17: * ipspiel21-tictactoe-core. If not, see <http://www.gnu.org/licenses/>.
18: */
19: package de.fhdw.gaming.ipspiel21.viergewinnt.core.domain;
20:
21: /**
22: * Represents the state of a Vier Gewinnt field.
23: */
24: public enum VierGewinntFieldState {
25:
26: /**
27: * The field is empty.
28: */
29: EMPTY("_"),
30:
31: /**
32: * There is a red piece on the field.
33: */
34: YELLOW("Y"),
35:
36: /**
37: * There is a yellow piece on the field.
38: */
39: RED("R");
40:
41: /**
42: * String for toString.
43: */
44: private String string;
45:
46: /**
47: * .
48: *
49: * @param string
50: */
51: VierGewinntFieldState(final String string) {
52: this.string = string;
53: }
54:
55: @Override
56: public String toString() {
57: return this.string;
58: }
59: }